Filling in Forms with MacHTTP

The following HTML and AppleScript examples are provided by Dennis Wilkinson as an example of how to get MacHTTP to deal with data from forms as supported by clients like XMosaic 2.0.

Note that this requires AppleScript!

HTML Form

<title>Feedback Form</title><h2>Submit your feedback</h2><form method=GET action="http:/form.script">Name: <input name="username"><p>E-Mail: <input name="usermail"><p><select name="feedback"><option selected>I Love It!
<option>I'm Lost!
<option>I Hate It!
</select><p><input type=submit value="Submit your feedback now"><p><input type=reset value="Reset this form"><p></form>
AppleScript for processing form data
tell window 1 of application "Scriptable Text Editor"
        set contents to http_search_args
        return "<title>Server Query Response</title><h1>Hi!</h1>We get the
picture. Thanks for the feedback.<P><address>Here</Address>"
end tell